package com.xlx.openLink.base;

import lombok.Data;

/**
 * @author seven
 * @create 2018-11-06 13:41
 **/
@Data
public class BasePageRequest {

    protected int pageSize = 10;

    protected int pageNum = 1;

    public BasePageRequest() {
    }

    public int getOffset() {
        return (pageNum - 1) * pageSize;
    }

    public int getPageSize() {
        return pageSize;
    }

    public void setPageSize(int pageSize) {
        this.pageSize = pageSize;
    }

    public int getPageNum() {
        return pageNum;
    }

    public void setPageNum(int pageNum) {
        this.pageNum = pageNum;
    }
}
